<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib prefix="s" uri="/struts-tags"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<script type="text/javascript">
function show(o){
	 //重载验证码

	 var timenow = new Date().getTime();
	 o.src="<%=basePath%>random.action?d="+timenow;
	 /*
	 //超时执行;
	 setTimeout(function(){o.src="<%=basePath%>random.action?d="+timenow;},20);
	  */
	}

</script>
</head>
<body>
<s:token></s:token>
<form action="Login.action?action=Login" method="post">
<p>密码：<input type="text" name="username" />
<p>账号：<input type="text" name="password" />
<p>验证码：<input type="text" name="validateTxt"/>
<p>
<a title="看不清吗？换一张吧！"  href='javascript:show(document.getElementById("random"))'>
<img src="<%=basePath%>random.action" id="random" border="0" /></a>
<p></p>
<input type="submit" value="登陆" /><p></p>
<a href="user/register.jsp">用户注册</a>
</form>
</body>
</html>